home *** CD-ROM | disk | FTP | other *** search
- #ifndef _XMALLOC_H_
- #define _XMALLOC_H_
-
- extern char *malloc();
- extern char *calloc();
- extern char *realloc();
- extern char *valloc();
- extern char *memalign();
-
- /*
- * As far as the user in concerned, this is an opaque struct. Maybe
- * define it as struct { int foo } and use the real definition inside
- * group.c?
- */
- typedef struct {
- char *head; /* The head of the linked list of objects */
- int magic; /* Just to make sure we really were passed a MemGroup */
- int count; /* Not strictly necessary, handy for debugging */
- } MemGroup;
-
- extern MemGroup *group_create();
- extern char *group_malloc();
-
- /*
- * You may or may not want this - In gcc version 1.30, on Sun3s running
- * SunOS3.5, this works fine.
- */
- #if defined(__GNUC__)
- #define alloca(n) __builtin_alloca(n)
- #endif /* __GNUC__
-
- /* Don't put anything after this line */
- #endif /* _XMALLOC_H_ */
-